#import "YLWebImageCompat.h"
#import "YLWebImageManager.h"


@interface UIImageView (YLWebCache)

- (void)yl_setImageWithURL:(nullable NSURL *)url NS_REFINED_FOR_SWIFT;

- (void)yl_setImageWithURL:(nullable NSURL *)url
          placeholderImage:(nullable UIImage *)placeholder NS_REFINED_FOR_SWIFT;

- (void)yl_setImageWithURL:(nullable NSURL *)url
          placeholderImage:(nullable UIImage *)placeholder
                   options:(YLWebImageOptions)options NS_REFINED_FOR_SWIFT;

- (void)yl_setImageWithURL:(nullable NSURL *)url
                 completed:(nullable YLExternalCompletionBlock)completedBlock;

- (void)yl_setImageWithURL:(nullable NSURL *)url
          placeholderImage:(nullable UIImage *)placeholder
                 completed:(nullable YLExternalCompletionBlock)completedBlock NS_REFINED_FOR_SWIFT;


- (void)yl_setImageWithURL:(nullable NSURL *)url
          placeholderImage:(nullable UIImage *)placeholder
                   options:(YLWebImageOptions)options
                 completed:(nullable YLExternalCompletionBlock)completedBlock;


- (void)yl_setImageWithURL:(nullable NSURL *)url
          placeholderImage:(nullable UIImage *)placeholder
                   options:(YLWebImageOptions)options
                  progress:(nullable YLWebImageDownloaderProgressBlock)progressBlock
                 completed:(nullable YLExternalCompletionBlock)completedBlock;


- (void)yl_setImageWithPreviousCachedImageWithURL:(nullable NSURL *)url
                                 placeholderImage:(nullable UIImage *)placeholder
                                          options:(YLWebImageOptions)options
                                         progress:(nullable YLWebImageDownloaderProgressBlock)progressBlock
                                        completed:(nullable YLExternalCompletionBlock)completedBlock __deprecated_msg("This method is misunderstanding and deprecated, consider using `YLWebImageQueryDiskSync` options with `yl_setImageWithURL:` instead");

#if YL_UIKIT

#pragma mark - Animation of multiple images

- (void)yl_setAnimationImagesWithURLs:(nonnull NSArray<NSURL *> *)arrayOfURLs;

- (void)yl_cancelCurrentAnimationImagesLoad;

#endif

@end
